<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script src="../js/jquery-1.11.3.js"></script>
</head>
<body>
<ul>
    <li>Apple</li>
    <li>Tomato</li>
</ul>
<ul>
    <li>Banana</li>
    <li>Potato</li>
    <li>Orange</li>
</ul>

<script type="text/javascript">
    $('li:first').css('color', 'red');
    $('li:last').css('color', 'blue');
</script>

</body>
</html>